package com.ysx.teacher.day20210909.ch05.iocc.entity;

import java.util.ArrayList;

public class Ch01 {

    public static void main(String[] args) {

        int[] array = new int[2];
        array[0]=10; array[1]=20;

        for(int index=0;index<array.length;index++){
            int value=array[index];
            System.out.println(value);
        }

        // 循环
        ArrayList arrayList = new ArrayList();
        arrayList.add(10);
        arrayList.add(20);
        for(int index=0;index<arrayList.size();index++){
            int value=(int)arrayList.get(index);
            System.out.println(value);

        }


    }
}
